<?php
class main extends Controller {
    public function index($request, $response) {
        $response->header('Content-Type', 'text/plain');
        $response->end('Hello Speedphp');
    }
    public function json($request, $response) {
        $response->header('Content-Type', 'application/json');
        $response->end('{"code":200,"msg":"Hello Speed"}');
    }
}